import random

def generate_test_cases(num_cases=100):
    test_cases = []

    # 生成各种范围的测试用例
    ranges = [
        (0, 255),          # 8位数字
        (256, 65535),      # 16位数字
        (65536, 4294967295) # 32位数字
    ]

    for start, end in ranges:
        cases = num_cases // len(ranges)
        for _ in range(cases):
            n = random.randint(start, end)
            test_cases.append(n)

    # 添加一些边界情况
    special_cases = [0, 1, 2, 3, 255, 256, 65535, 4294967295]
    test_cases.extend(special_cases)

    # 将测试用例写入文件
    with open('input.txt', 'w') as f:
        f.write(f"{len(test_cases)}\n")
        for case in test_cases:
            f.write(f"{case}\n")

if __name__ == '__main__':
    generate_test_cases()
